package xzs.wx.wxappFace;

import com.tencentcloudapi.common.Credential;
import com.tencentcloudapi.common.profile.ClientProfile;
import com.tencentcloudapi.common.profile.HttpProfile;
import com.tencentcloudapi.faceid.v20180301.models.BankCard2EVerificationResponse;
import com.tencentcloudapi.faceid.v20180301.models.DetectAuthResponse;
import xzs.wx.wxappFace.service.GetBizTokenService;
import xzs.wx.wxappFace.vo.GetBizTokenRequest;
import xzs.wx.wxappFace.vo.GetInteractiveVideoResult;

// 导入对应产品模块的 client
// 导入要请求接口对应的 request response 类

public class GetInteractiveVideoResultService {
    public static void main(String[] args) {
        try {

            Credential cred = new Credential("AKIDSffNBnxDWZOwFI4dZEdmtGMAiwtZF85i", "XoGUP3UouqWv2tvkSwGI8hzyhJeqlQov");

            HttpProfile httpProfile = new HttpProfile();
            httpProfile.setEndpoint("faceid.tencentcloudapi.com");

            ClientProfile clientProfile = new ClientProfile();
            clientProfile.setHttpProfile(httpProfile);

            GetBizTokenService client = new GetBizTokenService(cred, "ap-guangzhou",clientProfile);

            GetInteractiveVideoResult req = new GetInteractiveVideoResult();
            req.setBizToken("6AB33C8A-43C4-498F-A4A4-0D3BDC5A55B0");
            req.setNeedVideo(true);

            BankCard2EVerificationResponse resp = client.getInteractiveVideoResult(req);

            System.out.println(DetectAuthResponse.toJsonString(resp));
        } catch (Exception e) {
            System.out.println(e.toString());
        }


    }

}